package com.example.guiguiapplicatio.api.Interface;

import com.example.guiguiapplicatio.databindingBean.Doctor;
import com.example.guiguiapplicatio.Response.FamilyarSigning;
import com.example.guiguiapplicatio.Response.Record;
import com.example.guiguiapplicatio.Response.ServicePackageResponse;
import com.example.guiguiapplicatio.Response.Signing;
import com.example.guiguiapplicatio.Response.Signingdetail;
import com.example.guiguiapplicatio.databindingBean.followup.FollowupWith;
import com.example.guiguiapplicatio.databindingBean.followup.ListFollowupWith;
import com.example.guiguiapplicatio.util.ResponseBody;


import java.util.List;

import retrofit2.Call;

import retrofit2.http.Body;
import retrofit2.http.DELETE;
import retrofit2.http.GET;
import retrofit2.http.POST;
import retrofit2.http.PUT;
import retrofit2.http.Path;
import retrofit2.http.Query;

public interface Api {
    //黎姓男子御用api
    @POST("followUp/addFollowUp")
    Call<ResponseBody<Object>> upLoadFollowUp( @Body FollowupWith  followupWith);
    @GET("followUp/getOne")
    Call<ResponseBody<FollowupWith>> getOneFollowupWith(@Query("id") Integer id);
    @POST("followUp/deleteFollowUp")
    Call<ResponseBody<Object>> deleteFollowUp( @Body FollowupWith  followupWith);

    @POST("followUp/updateFollowUp")
    Call<ResponseBody<Object>> updateFollowUp( @Body FollowupWith  followupWith);

    @GET("v3/weather/now.json")
    Call<Object> getCall(@Query("key")String key,@Query("location") String location);//测试
    @GET("/followUp/getFollowUpType")
    Call<ResponseBody<List<String>>>   getOnesFollowUpType(@Query("idcard")String idcard);

    @GET("/followUp/list")
    Call<ResponseBody<List<ListFollowupWith>>> getFollowUpList(@Query("PageBegin")Integer PageBegin , @Query("PageSize") Integer PageSize,
                                                               @Query("timeLimit")String timeLimit, @Query("dateA")String dateA,
                                                               @Query("dateB")String dateB, @Query("state")Integer state,
                                                               @Query("type")String type,@Query("searchString")String searchString);
    @GET("/signing/searchNowServering")
    Call<ResponseBody<List<Record>>> searchNowServering(@Query("PageBegin")Integer PageBegin , @Query("PageSize") Integer PageSize,
                                                        @Query("searchString")String searchString);

    @POST("/doctor/login")
    Call<ResponseBody<Doctor>> login(@Body Doctor doctor);

    //黎姓男子御用api

    //  家庭Api
    @POST("FamilyarChives/addMember")
    Call<Object> addFamilyarChives(@Query("householdId")String householdId , @Query("memberId") String memberId);
    @POST("FamilyarChives/add")
    Call<Object> addNewFamilyarChives(@Query("IdCard")String IdCard);
    @PUT("/FamilyarChives/UpDate")
    Call<Object> updateFamilyarChives(@Query("IdCard")String IdCard,@Query("relationship")String relationship);
    @DELETE("/FamilyarChives/delete")
    Call<Object> deleteFamilyarChives(@Query("IdCard")String IdCard);
    @GET("FamilyarChives/signingList")
    Call<ResponseBody<FamilyarSigning>> getFamilyarChivesSigningList(@Query("IdCard")String IdCard, @Query("doctorId") int doctorId);
    @GET("/signing/getNowServering/idCard")
    Call<ResponseBody<Signing>>  getByNowServingById(@Query("IdCard")String IdCard);
    @GET("/signing/state")
    Call<ResponseBody<List<Signing>>> getAllstateSigning(@Query("IdCard")String IdCard,@Query("StaTime")String StaTime,@Query("EndTime")String EndTime);
    @GET("/record/idcard/{idcard}")
    Call<ResponseBody<Object>> getRecordById(@Path("idcard") String IdCard);
    //服务包Api
    @GET("servicepack/Type")
    Call<ResponseBody<List<ServicePackageResponse>>> getServicePackByType(@Query("type")String type);
    @GET("/signing/Signingdetail")
    Call<ResponseBody<Signingdetail>> getSigningdetail(@Query("signingId")int signingId);
    @DELETE("/signing/trueId/{id}")
    Call<ResponseBody<Object>> deleteSigning(@Path("id") int id);
    @POST("/signing/SearchFamilySigning")
    Call<ResponseBody<List<List<Record>>>> SearchFamilySigningAll(@Query("familyarchooseserviceListJson") String familyarchooseserviceListJson , @Query("StaTime")String StaTime , @Query("EndTime")String EndTime);
    @POST("/doctor/ChangePassword")
    Call<ResponseBody<Object>> ChangePassword(@Query("newPassword")String newPassword,@Query("oldPassword")String oldPassword,@Query("doctorId")int doctorId);
}